﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using NextInventory.Model;
using NextInventory.Model.Manufacturer;
using NextInventory.Model.Order;
using NextInventory.Model.Purchase;
using NextInventory.Model.Sale;
using NextInventory.Model.User;

namespace NextInventory.Model.Inventory
{
    public class ProductModel : BaseViewModel
    {
        public long ProductId { get; set; }
        public string Name { get; set; }
        public string Description { get; set; }
        public DateTime? ExpiryDate { get; set; }
        public DateTime PurchaseDate { get; set; }
        public DateTime? MenuFacturingDate { get; set; }
        public int OpeningQty { get; set; }
        public int OpeningValue { get; set; }
        public decimal PurchaseRate { get; set; }
        public decimal SaleRate { get; set; }
        public int? CategoryId { get; set; }
        public int MenufacturerId { get; set; }
        public long? ModelId { get; set; }
        public long? CreatedBy { get; set; }
        public DateTime? CreatedDate { get; set; }
        public long? UpdatedBy { get; set; }
        public DateTime? UpdatedDate { get; set; }

        public CategoryModel Category { get; set; }
        public virtual ManufacturerModel Menufacturer { get; set; }
        public virtual CategoryModel Model { get; set; }
        public virtual List<OrdersDetailModel> OrdersDetails { get; set; }
        public virtual List<PurchaseDetailModel> PurchaseDetails { get; set; }
        public virtual List<PurchaseReturnDetailModel> PurchaseReturnDetails { get; set; }
        public virtual List<SaleModel> SaleDetails { get; set; }
        public virtual List<SaleReturnModel> SaleReturnDetails { get; set; }
    }

    public class CategoryModel : BaseViewModel
    {
        public long ModelId { get; set; }
        public string Name { get; set; }
        public string Description { get; set; }
        public bool IsActive { get; set; }
        public long CreatedBy { get; set; }
        public DateTime CreatedDate { get; set; }
        public long UpdatedBy { get; set; }
        public DateTime UpdatedDate { get; set; }

        public virtual UserModel User { get; set; }
        public virtual UserModel User1 { get; set; }
        public virtual List<InventoryModel> Products { get; set; }

    }
    public class ProductCategoryModel : BaseViewModel
    {
        public int CategoryId { get; set; }
        public string Name { get; set; }
        public string Description { get; set; }

        public virtual List<InventoryModel> Products { get; set; }
    }
}